package com.itheima.kuozhan;

import java.lang.annotation.Annotation;
import java.util.Arrays;

public class Demo01 {

    public static void main(String[] args) {
        Zi zi= new Zi();
        Class<? extends Zi> clazz = zi.getClass();
        //获取父类
        Class<?> die = clazz.getSuperclass();
        System.out.println(die);
        Class<?>[] interfaces = clazz.getInterfaces();
        System.out.println(Arrays.toString(interfaces));

        Annotation annotation = clazz.getAnnotation(Override.class);


        System.out.println(annotation);
        Annotation[] annotations = clazz.getAnnotations();
        System.out.println(Arrays.toString(annotations));


    }
}
